package com.flyduck.logback.controller;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p></p>
 *
 * @author flyduck 2020/10/16 22:56
 * @version V1.0
 * @modify by user: LiuHui 2020/10/16
 * @modify by reason:{原因}
 **/
@RestController
@RequestMapping("log")
public class LogbackController {

    private static final Logger LOGGER = LoggerFactory.getLogger(LogbackController.class);

    @GetMapping("{id}")
    public String log(@PathVariable String id) {
        LOGGER.info("获取 ID={} 详情接口", id);
        return id;
    }
}
